//
//  AWServeAppEventMessage.m
//  AtWork2
//
//  Created by lucas on 15/6/4.
//  Copyright (c) 2015年 Foreveross. All rights reserved.
//

#import "AWEventChatMessage.h"

@interface AWEventChatMessage ()

@property (nonatomic, copy, readwrite) NSString *eventValue;

@end

@implementation AWEventChatMessage

+ (instancetype)eventChatMessageFrom:(NSString *)from to:(NSString *)to content:(NSString *)content {
    return [[self alloc] initWithFrom:from to:to content:content];
}

- (instancetype)initWithFrom:(NSString *)from to:(NSString *)to content:(NSString *)content {
    if (self = [super initWithFrom:from to:to messageType:AWMessageTypeServeNo]) {
        self.chatMessageType = AWChatMessageTypeEvent;
        self.eventValue = content;
    }
    return self;
}

#pragma mark - Getter Setter Methods

- (void)setEventValue:(NSString *)eventValue {
    [self bodyWithKey:AWMessageKEventType value:eventValue];
}

- (NSString *)eventValue {
    return [self bodyValueForKey:AWMessageKEventType];
}

@end
